home *** CD-ROM | disk | FTP | other *** search
/ Developer CD Series 1999 May: Tool Chest / Developer CD Series Tool Chest (Apple Computer)(May 1999).iso / Tool Chest / Games / Game Sample Code / ZAM 1.0a13 / GameHeaders / xqueue.h < prev    next >
Encoding:
C/C++ Source or Header  |  1993-09-16  |  713 b   |  31 lines  |  [TEXT/KAHL]

  1. #pragma once
  2. #include <Retrace.h>
  3.  
  4. typedef    struct xQHdr {        
  5.     long            qFlags;
  6.     struct xthing    *qHead;
  7.     struct xthing    *qTail;
  8.     short            qEntries;
  9. } xQHdr;
  10.  
  11. typedef Boolean (*updateProc)(struct xthing *xtp);
  12.  
  13. typedef struct xthing {
  14.     VBLTask            timer;            /* update time */
  15.     QElem            *xqel;            /* link in xthing queue */
  16.     short            prime;            /* number of miliseconds between runs */
  17.     xQHdr            *uQueueRef;        /* handy place to put your gum */
  18.     long            flags;            /* indicating stuff */
  19.     long            refcon;
  20.     updateProc        updtProc;
  21.     ProcPtr            vTaskPtr;
  22. } xthing;
  23.  
  24.  
  25. void xInitQueueHeader(xQHdr *queue);
  26. void xEnqueue(xthing *qel, xQHdr *queue);
  27. void xDequeue(xthing *qel, xQHdr *queue);
  28.  
  29. #ifndef nil
  30. #define nil ((void*)0L)
  31. #endif